Search Results

Establishing a git workflow with VSTS and Visual Studio

Here at sabin.io we use VSTS backed by git repos. We have a wide range of ability in git and though some of us have being using git for several years, we are not git wizards. The this is git cartoon by the folks over at xkcd.com pretty much sums up my early experiences, which in turn enforced narrowing my use of git to a limited workflow and a preference of git bash over GUI. And so, even though I’ve been using git for several years, I have only scratched the surface. When tasked with defining our workflow, I found I

Visual Studio Code Extensions and Settings

I primarily work in Visual Studio 2017 and Visual Studio Code, using VS2017 for SSDT work, and VS Code for pretty much everything else. VS code is highly configurable, and as it’s a rainy Sunday, I thought I’d share my settings with you in case you are interested. A few colleagues at work have asked me what extensions and settings I have so, here they are as of Feb 2018. Extensions In a console session within vs code, you can do this to list them: PS C:\> code --list-extensions codezombiech.gitignore DotJoshJohnson.xml eamodio.gitlens gerane.Theme-Blackboard mohsen1.prettify-json ms-mssql.mssql ms-vscode.PowerShell ms-vsts.team PeterJausovec.vscode-docker secanis.jenkinsfile-support yzhang.markdown-all-in-one

Creating VSTS Extensions for Visual Studio Marketplace

Hello! One of the neat things about VSTS is the Visual Studio Marketplace. To quote the VSTS Support Page , the Visual Studio Marketplace is “new destination and the exclusive place for purchasing subscriptions, and for discovering extensions for Visual Studio Team Services and Visual Studio Code.” OK, sounds pretty exciting. But what is an Extension? Again, let’s use Microsoft’s own documentation about Extensions – “Extensions are simple add-ons that can be used to customize and extend your DevOps experience with VSTS. They are written with standard technologies - HTML, JavaScript, CSS - and can be developed using your preferred

Establishing a git workflow with VSTS and Visual Studio - git rebase

In this post I will look at git rebase in Visual Studio, in particular rebasing a working branch onto master and at what happens to each commit. This post will not make a case for rebase over alternatives, though the findings will contribute to the workflow that will be decided upon. All posts in this series on establishing a git workflow for VSTS and Visual Studio are: Establishing a git workflow with VSTS and Visual Studio Configuring a VSTS repo from the Github sample repo Git merge Git rebase (this post) Recap on setup If you have just landed on

Establishing a git workflow with VSTS and Visual Studio - git merge

In this post I will look at git merge in Visual Studio, in particular merging down from master into a branch and at what happens to each commit. This post will not make a case for merge over alternatives such as rebase, though the findings will contribute to the workflow that will be decided upon. All posts in this series on establishing a git workflow for VSTS and Visual Studio are: Establishing a git workflow with VSTS and Visual Studio Configuring a VSTS repo from the Github sample repo Git merge (this post) Git rebase Recap on setup If you

T SQL Tuesday: Shipping Database Changes with SSDT

Hello! Let’s see how this goes: this months subject for T SQL Tuesday is about shipping database changes, something we here are all familiar with. So I thought I’d make some notes about a tool I’m very familiar with, SQL Server Data Tools. The Good It’s free! SSDT works with Visual Studio Community up to Ultimate, and from Visual Studio 2015 onwards it comes with it’s own Visual Studio IDE. SSDT Has a NuGet package available. So you don’t need to install Visual Studio to get builds running, and crucially can control which version is used to compile at a

How To Use MSBuild Arguments in Visual Studio Builds

When creating MSBuild.proj files for builds in Visual Studio, there are times when you might want some targets called, and other times you don't want the targets called. In my case, our Production builds compile all the web and windows service solutions as well asthe deployment scripts for databases and our BIDS projects. Essentially everything I would want if I was going to run an entire deployment for a release. However when deploying a dll hotfix, I don't want the SQL scripts and BIDS stuff built. When we want to deploy a hotfix, speed is of the essence. Our build

Establishing a git workflow with VSTS and Visual Studio - pull requests

In this post I will look at pull request processing in VSTS. Over and above the pull request process, what is also interesting is any differences in the commit graph on the remote repo when merging up from a merged as compared to a rebased branch. As with previous posts in this series, this post will not make a case for either, though findings will contribute to the workflow that will be decided upon. All posts in this series on establishing a git workflow for VSTS and Visual Studio are: Establishing a git workflow with VSTS and Visual Studio Configuring

VSTS Git Repos no longer show as connected in Visual Studio

I hit something this week where one of my Git repos showed as disconnected in Visual Studio and Team Explorer was showing me the option to clone the repo. Which clearly I didn’t want to do as it was already cloned. You can see in the picture that I have the repo locally (at the bottom) but in the list of projects I get the clone button.   The root cause of this was that VSTS has been cleaning up an old artefact of its TFS history. For on premise TFS you have the ability to have collections, and one

Establishing a git workflow with VSTS and Visual Studio - configuring a VSTS repo from the Github sample repo

Mid-way through writing what I expected to be the second post on establishing a git workflow with VSTS and Visual Studio, I realised the second post needed to be about configuring a VSTS repo from the Github sample repo git_workflow_sample_setup , since this action will be repeated for each of the subsequent posts that will look into merge, rebase and commit squashing. The sample code and branch structure are described in the first post Establishing a git workflow with VSTS and Visual Studio . First of all Throughout this post I assume the reader has some familiarity with VSTS. When

Feedback requests to Microsoft

If you didn’t know Microsoft has a number of channels to provide feedback. Most historically user connect (connect.microsoft.com), it integrated with their internal bug tracking systems and meant that items flowed from the users to engineering and back. Well supposed to.   The SQL product group still use connect https://connect.microsoft.com/sql with a few teams also using Trello https://trello.com/b/NEerYXUU/powershell-sql-client-tools-sqlps-ssms and or Slack Slack - sqlcommunity.slack.com Visual studio is moving to https://developercommunity.visualstudio.com/spaces/8/index.html from connect and also has https://visualstudio.uservoice.com/forums/121579-visual-studio-ide for ideas VSTS has a great support and also uses MSDN, and takes requests on Uservoice https://visualstudio.uservoice.com/forums/330519-team-services PowerBI has forums and uses user voice

How To Compile SQLProj Files Using Cmdline MSBuild... Errors Included!

I recently needed to build and deploy about 40 small database projects that were in 4 or 5 different database solutions. And I needed to do this several times a day, so compiling via Visual Studio would be a boring and tedious process. So to speed up the process I decided to write the build process in an MSBuild target file and call initiate the build process through PowerShell. The targets file was simple enough to put together. This would be saved in the root location of all the solution folders as "BuildAllDBProjects.targets.xml". Then the PowerShell would be simple enough;

Why is SSDT Always Rebuilding My Constraints?

Hello! Let me begin by saying that I’m a big fan of SSDT. It’s free, it works with all flavours of Visual Studio, the team do their very best to keep up-to-date with features that are released with increasing regularity by Microsfot in both Azure and SQl Server on-prem. I’ve met the team a few times, and they’re genuinely keen to engage with the users of SSDT in how it can be better, and how it can be extensible. So, SSDT is a great tool. I said great, but not perfect. It has it's limitations, the same as any tool.

Keeping The Database Dev Ops Overhead Lightweight

Hello! One very important aspect of Dev Ops that is perhaps over-looked is the overhead that comes with adopting Dev Ops practices. To help explain what I mean, let’s break that sentence down a bit. What Do I Mean By “Dev Ops Practices” I have a strong suspicion that for each of the posts for this T-SQL Tuesday on Database Dev Ops, everyone will have a slightly different take. Or rather, they are going to articulate what Dev Ops means to them. And so here is my take: broadly speaking, Dev Ops is about increasing the cadence of a feature

SQL Supper Scripts

Hello! Thanks to everyone who turned up yesterday at SQL Supper: there was a good turnout of both new and familiar faces. The Demo Gods were with me and I was able to log on to both my Azure VM and able to deploy to SQL Azure. I’ve uploaded the scripts to gist and shared below. I also spoke about raising a Connect Issue so that Microsoft.Build.Utilities.Core NuGet package will work with Microsoft.Data.Tools.Msbuild. I’d like to see this so that we do not have to install the Microsoft Build Tools 2015 MSI on the box. And this is important because

SSDT 16.5 Released

Hello! Recently the SQL Tools Team released a new version of both SQL Server Data Tools ( SSDT ) and SQL Server Management Studio (SSMS.)  There’s a range of bug fixes, but two new features that I am particualrly interested in. Firstly, SQLPAckage.exe and the DacFx API can now generate deployment report, deployment script and publish to a datbase all in one action. Neat! This is useful because it’s important to keep track of exactly what has changed on a database. Of course there’s nothing stopping you right now from creating executin these options in three separate actions, but there

Where To Find Us at SQLBits

Hello! SQLBits is back! This year SQLBits is being hosted in the Grand Hallway at the Olympia which was opened way back in 1886. This marks the return of Bits to London, and in fact the south of England, for the first time since 2015. Back then it was hosted at the Excel Exhibition Centre in the East of London. If you have never heard of SQLBits before, I’d be very surprised as it is the largest SQL Server Conference in Europe and offers world class training. But enough about the brief history lesson, let’s talk about what’s coming up

Automating SQL Server Performance Testing

You run performance tests as well as functional tests when deploying new code changes to SQL Server, right? Not many people do, I think you should, and this article will show you how to do it by harnessing an existing performance tool, rather than writing your own monitoring infrastructure from scratch. Any good performance monitoring tool that records information to a database will do fine, and we prefer to use Sentry One . Here are the steps to accomplish this. Create a baseline database When you release your database change, you want to have something to compare against as an

Microsoft Release SQL Server 2016 SP1 and Give Stuff Away!

Today was the Connection (); 2016 Keynote, and it was certainly was worth tuning into to catch-up with what Microsoft have been up to. I was going to write a brief summary of the Keynote and made some notes in a text file, but an hour in to the 2 hour presentation I gave up because there was so much going on. Microsoft have been pushing for an Incremental Service Modelling , to the point that they changed the recommendation from Cumulative Updates being deployed only if you are affected by any of the issues to always update . This

Uploading Files To Data Lake Store With PowerShell Part One

Hello!   I’ve recently been working on uploading files to Azure Data Lake Store . It’s quite straightforward and I think a decent introduction into automating a deployment with Azure, as well as a good example of writing scripts that are idempotent, so I’m going to go through them from beginning to end. I’m going to go into one function per day, so this will take 5 days to cover. But I’m hoping that by focusing a bit more in-depth as opposed to trying to cram it all into one post it will be more informative, and both yourselves and

Migrating SSIS Packages to SSIS Azure part Two – Automating the Deployment

Hello! If you’ve read and followed through my previous post, you will have World Wide Importers Integration Services project running in SSIS Azure. It’s all very interesting, go and have a read . One thing that is missing form that guide, the documentation, and SSIS in general, is how to automate SSIS Deployments. In the WWI SSIS project, there are connection managers that we had to manually update the values of to get it to work post-deploy. This is exactly the opposite of what we want to do. Back when SQL Server 2012 was known as Denali, one of the

Continuous Integration with Jenkins, SQL Server and Windows Containers

Why use Windows Containers? When creating database applications we need consistency in all our environments to ensure quality releases. Traditionally developers might have their own instance of SQL Server on their workstation to develop against. Database projects would be created in SSDT and pushed to source control when ready for testing. If you’re not using SSDT for database development already, then you should seriously consider it to make your life easier and increase the quality of your releases. Ed Elliot explains why in this blog post . A problem with CI for databases is that databases are a shared resource

Git: How to work on a feature branch but pull in later commits from another branch?

On a client site last week the question was raised: I want to work on a feature for a project which will take longer than other people merging their branches into the dev branch. I therefore want to merge any changes on the dev branch into mine, test my changes before pushing back to the dev branch, and then and ultimately master for a release. We are using a git flow methodology whereby the development manager will merge feature branches from developers’ branches via pull requests into the dev branch. Tests are run and if they pass, we merge into

Migrating SSIS Packages to SSIS Azure

Hello! In case you missed the announcement (and there were a lot of announcements during MSIgnite), SQL Server Integration Services is in Public Preview on Azure! I’ve written about it elsewhere in greater depth , but here are the headlines: It makes use of SSIS Scale Out , which was released as part of SQL Server 2017 . Although it is based on SSIS Scale Out, you can’t actually configure SSIS Scale Out to run on the instance. If this confuses you then read my in-depth post. SSISDB is installed in either SQL Azure or on a Managed Instance. You

Fix For Using Azure Active Directory and DacFX

Hello! As part of an SSDT project we have a contained user that authenticates against an Azure Active Directory group (read more on the CREATE USER page). However the account we are executing deployments with is the SQL Admin account on the Azure SQL Instance. And so we get this error - The executed script: CREATE USER [myUser] FOR EXTERNAL PROVIDER; ' Reason: '' At line:94 char:13 + Throw $toThrow + ~~~~~~~~~~~~~~ + CategoryInfo : OperationStopped: (Deployment fail... ' Reason: '':String) [], RuntimeException + FullyQualifiedErrorId : Deployment failed: 'Could not deploy package. Error SQL72014: .Net SqlClient Data Provider: Msg 33159,

VMWare network performance bug - Getting a repro

If you’ve read my previous post about an issue with VMware ESX 6 and connecting to SQL and 500ms latency , you might be interested in the process we went through to get to the repro. Getting a repro (being able to reproduce a bug/feature) is often a complex and time consuming task. The challenge is like being Sherlock Holmes and using your experience to focus on the aspects of the situation that is important. The challenge is that without a repro, You can’t give anything to a supplier to enable them to triage and find a fix for it

SSIS Package Execution In Azure Is Now Available

Well, it’s been some time coming but SSIS packages are the latest product to make the move from on premise to Azure. You can now take your SSIS projects and deploy them to the new Platform as a Service (PaaS) offering in Azure. The aim of the team at Microsoft was for users to take their current SSIS packages and just “lift and shift” these to Azure. So in development terms that means that there are minimum to no changes to be made in the solution at least. But before we get into the deployment and running of SSIS packages